'use strict';

module.exports = app => {
    const {
        DATE,
        STRING,
        INTEGER
    } = app.Sequelize;
    const system_input = app.model.define('system_input',{
        id:{
            type:INTEGER,
            primaryKey:true,
            autoIncrement:true,
            allowNull:false,
            comment:"千分制录入ID"
        },
        class_name:{
            type:STRING,
            defaultValue:null,
            comment:"班级名字"
        },
        name:{
            type:STRING,
            defaultValue:null,
            comment:"名字"
        },
        rule_class:{
            type:STRING,
            defaultValue:null,
            comment:"类型"
        },
        rule_name:{
            type:STRING,
            defaultValue:null,
            comment:"规则选项"
        },
        score:{
            type:INTEGER,
            defaultValue:null,
            comment:"分值"
        },
        date:{
            type:DATE,
            defaultValue:null,
            comment:"日期"
        },
        explain:{
            type:STRING,
            defaultValue:null,
            comment:"说明"
        },
        valid:{
            type:STRING,
            defaultValue:"1",
            comment:"是否有效(1为有效0为无效)"
        }
    })
    system_input.associate = function () {
        
    }
}